
/* -----------------
* brief 
* 1. this is code gen by tools 
* 2. array like [a,b,c] after each field, define the ui html tag in view, 
		a for title, 
		b for show or not ,  
		c for element html tag , currently suppor : check、radio、select、input、textarea、upload tag
* 3. XXX
*/

package config

import "github.com/mjiulee/lego"

import (
	"saas_sys_base/common"
)

func init() {
	lego.AddBeanToSynList(new(Config))
}

/* table: "tb_config"
 * -----------------
*/
type Config struct {
	Id        int64  `xorm:"pk" json:",string"`                  // ["id","hide","hidden"]
	IfDel     int `xorm:"default 0"` // ["deleted","hide","hidden"]
	Cdate     string `xorm:"DateTime created"`    // ["create","show","datetime"]
	Udate     string `xorm:"DateTime updated"`    // ["update","show","datetime"]
    // add your custom field here
    common.Who `xorm:"extends"`
    Version string `xorm:"char(32)"` // ["Version","show","input"]
	//使用ARCH_LEVEL_XXX定义数值，系统0， 租户1， 应用2， 用户3； 0级别最高，
	//等于或高于定义级别，才能使用配置，否则可以给予下级继承并用于作为默认配置
    PermissionLevel int `xorm:"int"` // ["PermissionLevel","show","input"]
    ConfigName string `xorm:"char(64)"` // ["configData","show","textarea"]
	ConfigData     string `xorm:"text"` // ["configData","show","textarea"]

}